<html>
<head>

<title>Alterar uma pizza</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<style type="text/css">

	input[type=text] {
		width: 500px;
	}

</style>
	
</head>

<body bgcolor="#FFFFFF" text="#000000">
<?
	include "conexao.php";
	$conec;
	$bco;

	include "cabecalho.php";
	$codigo = $_POST['txcod'];

	$stgsql = $conec->prepare("select * from pizzas where codigo = \"$codigo\"");
	$stgsql->execute();

	if ($stgsql->rowCount() > 0) {
		
		$dados     = $stgsql->fetch();
		$codigo    = $dados['codigo'];
		$nome      = $dados['nome'];
		$descricao = $dados['descricao'];
		$valor     = $dados['valor'];
		include "frmalterapizza2.php";
		
	} else {
		
		include "pizzanaoexiste.php";
		
	}

	include "rodape.php";

?>
</body>
</html>